home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / asmutil / ma22#2.zip / EXAMPLE1.09 < prev    next >
Text File  |  1991-08-21  |  1KB  |  56 lines

  1. *
  2. * Sample source file for the Motorola 6809
  3. *
  4. * (this program does not do anything, it is only an example)
  5. *
  6.     title   Sample source file
  7. *
  8. * Definitions
  9. *
  10. cr      equ     $0d     ;carriage return
  11. lf      equ     10      ;line feed
  12. RAM:    equ     $2000   ;memory start
  13. ppi0    equ     $8000   ;ppi 0
  14. crppi0  equ     ppi0+1  ;control register
  15. srppi0  equ     ppi0+2  ;status register
  16. flag    equ     123     ;flag bit
  17. offset  set     0
  18. *
  19. * Variables
  20. *
  21.     org     RAM     ;variables
  22. key     rmb     16      ;key buffer
  23. table   rmb     2+3*$10 ;address table
  24. loop1:
  25. offset  set     9
  26. *
  27. * Program
  28. *
  29.     lda     #'*'
  30.     clrb
  31.     pshs    b,cc,x,y,pc
  32.     exg     x,y
  33.     lda     6,y
  34.     ora     ,x++
  35.     anda    [3,pc]
  36.     sta     [$1000]
  37.     setdp   $10
  38.     lda     $1035
  39.     ldb     messg1+offset
  40.     ora     #flag
  41.     ldb     #10
  42.     jsr     delay
  43.     bra     loop1
  44. *
  45. * Delay routine
  46. *
  47. delay:  decb
  48.     rts
  49. *
  50. * Dummy data
  51. *
  52. routines fdb $1234,$f800,0 ;routine addresses
  53. messg1  fcc     cr,lf,'String no 1.',0
  54. messg2  fcb     cr,lf,lf,'Press a key.',0
  55.     end
  56.